package cn.rongdao.jrkabao.ui.cashcoupon.mycashcoupon.adapter;

import android.content.Context;
import android.view.ViewGroup;

import com.mifengkong.frtools.ui.adapter.recyclerview.FRBaseRecyclerAdapter;
import com.mifengkong.frtools.inputmethod.FRView;

import cn.rongdao.jrkabao.R;
import cn.rongdao.jrkabao.bean.cashcoupon.GetCashCouponBean;

/**
 * Created by jack on 2017/8/14
 */

public class CashCouponAdapter extends FRBaseRecyclerAdapter<GetCashCouponBean, CashCouponViewHolder> {

    private boolean isUnUse;

    private boolean isInvalid;

    public CashCouponAdapter(Context context) {
        super(context);
    }

    @Override
    public CashCouponViewHolder onCreateViewHolder(ViewGroup parent, int viewType) {
        return new CashCouponViewHolder(FRView.inflateLayout(getContext(), R.layout.item_my_cash_coupon, parent, false), isUnUse, isInvalid);
    }

    public void setUnUse(boolean unUse) {
        isUnUse = unUse;
    }

    public void setInvalid(boolean inValid) {
        isInvalid = inValid;
    }
}